package com.cb.domain.service.system.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.cb.core.service.impl.GenericManagerImpl;
import com.cb.domain.model.system.Media;
import com.cb.domain.dao.system.CompanyDAO;
import com.cb.domain.dao.system.MediaDAO;
import com.cb.domain.service.system.MediaManager;
import com.cb.core.webapp.paging.PagingBean;

@Service
public class MediaManagerImpl extends GenericManagerImpl<Media, Long> implements MediaManager{
	
	@Autowired
	private MediaDAO mediaDAO;
	@Autowired
	public MediaManagerImpl(MediaDAO mediaDAO) {
		super(mediaDAO);
		// TODO Auto-generated constructor stub
	}
	/**
	 * {@inheritDoc}
	 */
	public List<Media>getByVo(Media vo,PagingBean pb){
		return ((MediaDAO)genericDAO).getByVo(vo, pb);
	}
	@Override
	public Media getMediaBySort(int sort) {
		return ((MediaDAO) genericDAO).getMediaBySort(sort);
	}
}
